<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head th:include="base/base::head('机构管理',~{::link},~{::script},~{::style})">

    <link rel="stylesheet" th:href="${session.basePath}+'/resource/imp/system/css/orgSiteMgr.css'" />
    <script type="text/javascript" th:src="${session.basePath}+'/resource/plugins/wdfjslib/page.js'"></script>
    <script type="text/javascript" th:src="${session.basePath}+'/resource/imp/system/js/departmentMgr.js'" charset="utf-8"></script>
    <script type="text/javascript" th:src="${session.basePath}+'/resource/imp/system/js/orgSiteEdit.js'" charset="utf-8"></script>

</head>
<body class="page">

<form id='searchForm'>
    <div class="searchBar">
        <div class='searchInput' id='searchDepPanel'>

            <div class='block'>
                <div class='label'>
                    名称：
                </div>
                <div class='input1 input'>
                    <input type='text' name='name' placeholder="全部" maxlength="30"/>
                </div>
            </div>

            <div class='block'>
                <div class='label'>
                    编号：
                </div>
                <div class='input1 input'>
                    <input type='text' name='no' placeholder="全部" maxlength="30"/>
                </div>
            </div>

            <div class='block'>
                <div class='label'>
                    所属机构：
                </div>
                <div class='input1 input'>
                    <input type='text' id="dept_parent_SearchPanel" placeholder="全部" readonly="readonly"/>

                </div>
            </div>

            <div class='block'>
                <div class='label'>
                    机构类型：
                </div>
                <div class='input1 input'>
                    <input type='text' id="dept_type_SearchPanel" placeholder="全部" readonly="readonly"/>

                </div>
            </div>

            <div class="optBtnsBar">
                <input type='button' class="optBtn searchBtn" onclick='search()' value='查询'/>
                <input type='button' class="optBtn restBtn" onclick="resetSearch()" value="重置"/>

                <input type='button' class="optBtn searchBtn" onclick='addDepartment();' value='新增机构' />
            </div>

            <div style="clear:both"></div>

        </div>
    </div>
</form>

<div class="split"></div>

<div class="content">

    <div id="departmentGrid"></div>

</div>

<!-- 新增机构面板 -->
<div class="pannel_bg">
    <div class='panel' id="addDepPanel">
        <form id='addDepForm'>
            <input type='hidden' name='cType' value='PCWEB' placeholder="客户端类型"/>
            <div class='titleBar'><div class="title"></div><div class="closeBtn">返回</div></div>
            <div class='split'></div>
            <div class='content'>
                <table class='panelForm'>
                    <tr>
                        <td class='label'>上级机构：</td>
                        <td class='input'><input type='text' id='dept_parent_AddPanel' readonly="readonly"/></td>
                        <td class='info'><span style='color:red;'>*</span></td>
                    </tr>
                    <tr><td class='label'>机构名称：</td>
                        <td class='input'><input type='text' id='dept_name_AddPanel' name="name" maxlength="30"/></td>
                        <td class='info'><span style='color:red;'>*</span></td></tr>
                    <tr>
                        <td class='label'>机构类型：</td>
                        <td class='input'><input type='text' id='dept_type_AddPanel' placeholder="选择机构类型" readonly="readonly"/></td>
                    </tr>
                    <tr>
                        <td class='label'>排序：</td>
                        <td class='input'><input type='text' id='dept_orderNo_AddPanel' name="orderNo" maxlength="30"/></td>
                        <td class='info'><span style='color:red;'>*</span></td></tr>
                    <tr>
                        <td class='label lbTextarea'>备注：</td>
                        <td class='input'><textarea id="dept_description_AddPanel" rows="" cols="" name="description" maxlength="200" placeholder="最大输入200个汉字..."></textarea></td>
                    </tr>

                </table>
            </div>
            <div class='split'></div>
            <div class='btnBar'><input value="保存" class='okBtn zhuanjiao_btn' type="button"/><input value="取消" class='quxiao_btn' type="button"/></div>
        </form>
    </div>
</div>

<!-- 编辑机构面板 -->
<div class="pannel_bg">
    <div class='panel' id="editDepPanel">
        <form id='editDepForm'>
            <input type='hidden' name='cType' value='PCWEB' placeholder="客户端类型"/>
            <input type="hidden" id="department_id_EditPanel" name="id" value=""/>
            <div class='titleBar'><div class="title"></div><div class="closeBtn">返回</div></div>
            <div class='split'></div>
            <div class='content'>
                <table class='panelForm' >
                    <tr><td class='label'>上级机构：</td><td class='input'><input type='text' id='dept_parent_EditPanel' readonly="readonly"/></td><td class='info'><span style='color:red;'>*</span></td></tr>
                    <tr><td class='label'>机构编号：</td><td class='input'><input type='text' id='dept_no_EditPanel' name="no" readonly="readonly" maxlength="30"/></td></tr>
                    <tr><td class='label'>机构名称：</td><td class='input'><input type='text' id='dept_name_EditPanel' name="name" maxlength="30"/></td><td class='info'><span style='color:red;'>*</span></td></tr>
                    <tr>
                        <td class='label'>机构类型：</td>
                        <td class='input'><input type='text' id='dept_type_EditPanel' placeholder="选择机构类型" readonly="readonly"/></td>
                    </tr>
                    <tr>
                        <td class='label'>排序：</td>
                        <td class='input'><input type='text' id='dept_orderNo_EditPanel' name="orderNo" maxlength="30"/></td>
                        <td class='info'><span style='color:red;'></span></td></tr>
                    <tr>
                        <td class='label lbTextarea'>备注：</td>
                        <td class='input'><textarea id="dept_description_EditPanel" rows="" cols="" name="description" maxlength="200" placeholder="最大输入200个汉字..."></textarea></td>
                    </tr>

                </table>

            </div>
            <div class='split'></div>
            <div class='btnBar'><input value="保存" class='okBtn zhuanjiao_btn' type="button"/><input value="取消" class='quxiao_btn' type="button"/></div>
        </form>
    </div>
</div>

<!--机构、区域权限管理面板-->
<div class="pannel_bg">
    <div class='panel' id="orgAuthorityMgrPanel">
        <div class='titleBar' style="height: 73px;">
            <div class="closeBtn"></div>

        </div>
        <div class='split'></div>
        <div class='content' style="height: 100%;">
            <input type='hidden' name="id" id="deptAuthorityMgr_deptId"/>

            <div class="userAuthorityMgr_content">
                <div class="user_systemAuthority_box" id="user_systemAuthority_box">

                    <div class="selAuthorityBox indexAuth_box">
                        <div class="selAuthority_tit">机构信息</div>
                        <div class="selAuthority_content">
                            <div class="formContent">
                                <form  id="addFormPannel" autocomplete="off">

                                    <div class='block verificationInput'>
                                        <div class='label_detail'>
                                            上级机构：
                                        </div>
                                        <div class='input1_detail input_detail'>
                                            <input type='text' id='parent_department_addform' style="background: none;" readonly="readonly"/>
                                        </div>
                                    </div>
                                    <div class='block verificationInput'>
                                        <div class='label_detail'>
                                            机构名称：
                                        </div>
                                        <div class='input1_detail input_detail'>
                                            <input type='text' name="" readonly="readonly"  id="departmentName_addform"  style="background: none;"/>
                                        </div>
                                    </div>
                                    <div class='block verificationInput'>
                                        <div class='label_detail'>
                                            机构等级：
                                        </div>
                                        <div class='input1_detail input_detail'>
                                            <input type='text' name="" id="dept_level_addform" style="background: none;" readonly="readonly"/>
                                        </div>
                                    </div>

                                    <div class='block verificationInput'>
                                        <div class='label_detail'>
                                            备&nbsp;&nbsp;注：
                                        </div>
                                        <div class='input1_detail input_detail'>
                                            <input type='text' name="" id="dept_description_addform" style="background: none;" readonly="readonly"/>
                                            <!--<textarea name='' readonly="readonly" id="dept_description_addform" style="width: 300px; background: none; height: 51px;" maxlength="100" placeholder="最大输入100个汉字"></textarea>-->
                                        </div>
                                    </div>
                                </form>
                            </div>
                        </div>
                    </div>

                    <div class="selAuthorityBox">
                        <div class="selAuthority_tit">隧道权限
                            <input type="checkbox" class="authorityAllCheck" id="siteAllCheck"/>
                            <a id="checkAuthorityAllOrgBtn" class="checkAllBtn uncheckBtn" onclick="checkAuthorityAllSite(this)" href="javascript:void(0)">全选</a></div>
                        <div class="selAuthority_content">
                            <ul class="ztree" id="siteSel_tree"></ul>
                        </div>
                    </div>

                </div>
            </div>

        </div>

        <div class="split"></div>
        <div class='btnBar'>
            <input value="保存" class='okBtn zhuanjiao_btn' onclick="toSubOrgSite()" type="button"/>
            <input value="取消" class='quxiao_btn' type="button"/>
        </div>

    </div>

</div>

</body>
</html>